package fr.umlv.escape_ig.sprite;

import android.graphics.Canvas;
import android.graphics.RectF;

public abstract class Sprite {

        public final RectF rect;

        public boolean shouldDisapear = false;
        
        public Sprite(float left, float top, float right, float bottom) {
                this.rect = new RectF(left, top, right, bottom);
        }

        public void move(float dx, float dy) {
                rect.set(rect.left+dx, rect.top+dy, rect.right+dx, rect.bottom+dy); 
        }

        public abstract void draw(Canvas canvas);

        public abstract void update();
}
